/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package GUI;

/**
 *
 * @author CHX_93
 */
public class Gui_GhiDanh_2 extends javax.swing.JPanel {

    /**
     * Creates new form Gui_GhiDanh_2
     */
    public Gui_GhiDanh_2() {
        initComponents();
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        lb_guiHV_maKH = new javax.swing.JLabel();
        txt_guiHV_maKH_tt = new javax.swing.JTextField();
        lb_guiKH_trinhDo = new javax.swing.JLabel();
        cbo_guiKH_trinhDo_tt = new javax.swing.JComboBox();
        lb_guiKH_tgRanh = new javax.swing.JLabel();
        cbo_guiKH_tgRanh_tt = new javax.swing.JComboBox();
        btn_guiDK_themTGRanh = new javax.swing.JButton();
        cbo_guiKH_tgRanh_tt1 = new javax.swing.JComboBox();
        btn_guiDK_boTGRanh = new javax.swing.JButton();
        btn_guiDK_ok = new javax.swing.JButton();

        setBorder(javax.swing.BorderFactory.createTitledBorder("Đăng kí thi xếp lớp"));

        lb_guiHV_maKH.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        lb_guiHV_maKH.setText("Mã khách hàng:");
        lb_guiHV_maKH.setName("lbName"); // NOI18N

        txt_guiHV_maKH_tt.setHorizontalAlignment(javax.swing.JTextField.LEFT);
        txt_guiHV_maKH_tt.setName("txtName"); // NOI18N
        txt_guiHV_maKH_tt.addInputMethodListener(new java.awt.event.InputMethodListener() {
            public void caretPositionChanged(java.awt.event.InputMethodEvent evt) {
            }
            public void inputMethodTextChanged(java.awt.event.InputMethodEvent evt) {
                txt_guiHV_maKH_ttInputMethodTextChanged(evt);
            }
        });
        txt_guiHV_maKH_tt.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyTyped(java.awt.event.KeyEvent evt) {
                txt_guiHV_maKH_ttKeyTyped(evt);
            }
        });

        lb_guiKH_trinhDo.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
        lb_guiKH_trinhDo.setText("Trình độ:");
        lb_guiKH_trinhDo.setName("lbLevel"); // NOI18N

        cbo_guiKH_trinhDo_tt.setEditable(true);
        cbo_guiKH_trinhDo_tt.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Toiec", "Cùi mía", "ABC" }));
        cbo_guiKH_trinhDo_tt.setName("cboLevel"); // NOI18N

        lb_guiKH_tgRanh.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        lb_guiKH_tgRanh.setText("Thời gian rảnh:");
        lb_guiKH_tgRanh.setName("lbFreeTime"); // NOI18N

        cbo_guiKH_tgRanh_tt.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Sáng", "Trưa", "Chiều ", "Tối" }));
        cbo_guiKH_tgRanh_tt.setName("cboFreeTime"); // NOI18N

        btn_guiDK_themTGRanh.setText("Thêm");

        cbo_guiKH_tgRanh_tt1.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Thứ 2", "Thứ 3", "Thứ 4", "Thứ 5", "Thứ 6", "Thứ 7", "Chủ nhật" }));
        cbo_guiKH_tgRanh_tt1.setName("cboFreeTime"); // NOI18N

        btn_guiDK_boTGRanh.setText("X");

        btn_guiDK_ok.setText("OK");

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addContainerGap()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(lb_guiHV_maKH)
                            .addComponent(lb_guiKH_trinhDo, javax.swing.GroupLayout.PREFERRED_SIZE, 53, javax.swing.GroupLayout.PREFERRED_SIZE))
                        .addGap(4, 4, 4)
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(txt_guiHV_maKH_tt)
                            .addComponent(cbo_guiKH_trinhDo_tt, 0, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))
                    .addGroup(layout.createSequentialGroup()
                        .addComponent(lb_guiKH_tgRanh)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addGroup(layout.createSequentialGroup()
                                .addComponent(cbo_guiKH_tgRanh_tt, 0, 198, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(cbo_guiKH_tgRanh_tt1, 0, 187, Short.MAX_VALUE)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(btn_guiDK_boTGRanh)
                                .addGap(90, 90, 90))
                            .addGroup(layout.createSequentialGroup()
                                .addComponent(btn_guiDK_themTGRanh)
                                .addGap(0, 0, Short.MAX_VALUE))))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                        .addGap(0, 0, Short.MAX_VALUE)
                        .addComponent(btn_guiDK_ok)))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addGap(3, 3, 3)
                        .addComponent(lb_guiHV_maKH))
                    .addComponent(txt_guiHV_maKH_tt, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(6, 6, 6)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addGap(3, 3, 3)
                        .addComponent(lb_guiKH_trinhDo))
                    .addComponent(cbo_guiKH_trinhDo_tt, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(layout.createSequentialGroup()
                        .addGap(10, 10, 10)
                        .addComponent(lb_guiKH_tgRanh))
                    .addGroup(layout.createSequentialGroup()
                        .addGap(6, 6, 6)
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                            .addComponent(cbo_guiKH_tgRanh_tt, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(cbo_guiKH_tgRanh_tt1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addComponent(btn_guiDK_boTGRanh))))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(btn_guiDK_themTGRanh)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(btn_guiDK_ok))
        );
    }// </editor-fold>//GEN-END:initComponents

    private void txt_guiHV_maKH_ttInputMethodTextChanged(java.awt.event.InputMethodEvent evt) {//GEN-FIRST:event_txt_guiHV_maKH_ttInputMethodTextChanged

    }//GEN-LAST:event_txt_guiHV_maKH_ttInputMethodTextChanged

    private void txt_guiHV_maKH_ttKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_txt_guiHV_maKH_ttKeyTyped
        if(Character.isDigit(evt.getKeyChar()))
        {
            evt.consume();
        }
        if(!UIFormat.validStringLengthMax(txt_guiHV_maKH_tt.getText(), MyConst.MaxStringLength)){
            evt.consume();
        }
    }//GEN-LAST:event_txt_guiHV_maKH_ttKeyTyped


    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton btn_guiDK_boTGRanh;
    private javax.swing.JButton btn_guiDK_ok;
    private javax.swing.JButton btn_guiDK_themTGRanh;
    private javax.swing.JComboBox cbo_guiKH_tgRanh_tt;
    private javax.swing.JComboBox cbo_guiKH_tgRanh_tt1;
    private javax.swing.JComboBox cbo_guiKH_trinhDo_tt;
    private javax.swing.JLabel lb_guiHV_maKH;
    private javax.swing.JLabel lb_guiKH_tgRanh;
    private javax.swing.JLabel lb_guiKH_trinhDo;
    private javax.swing.JTextField txt_guiHV_maKH_tt;
    // End of variables declaration//GEN-END:variables
}
